home *** CD-ROM | disk | FTP | other *** search
/ Libris Britannia 4 / science library(b).zip / science library(b) / GRAPHICS / GRAPHUTL / 1344.ZIP / MANDLE.ARC / MSET12.DOC < prev    next >
Encoding:
Text File  |  1988-10-05  |  18.2 KB  |  351 lines

  1.                                 MANUAL VERSION 1.2
  2.                              MANDELBROT SET GRAPHICS
  3.                                 JULIA SET GRAPHICS
  4.       
  5.       
  6.       INTRODUCTION:
  7.       
  8.       Mandlebrot Set Graphics Version 1.2(MSET12) draws graphic 
  9.       representations of a function of a complex variable which were first 
  10.       introduced by Benoit Mandelbrot.  This is a shareware program and 
  11.       you are encouraged to copy it and pass it on.  It is not necessary 
  12.       to know the details of complex variables or their algebra to use or 
  13.       enjoy the fascinating behavior of the Mandelbrot Set.  It is 
  14.       helpful, however, to understand what is being plotted to navigate 
  15.       and explore the nearly limitless variety of designs to be found in 
  16.       the 'universe' of the Mandelbrot Set.
  17.       
  18.       If you have looked at the directory, you will have noticed that 
  19.       there is also a file titled JSET12.  This is a program which will 
  20.       generate graphics based on the Julia Set; a companion to the 
  21.       Mandelbrot Set.  This set is named after Gaston Julia, one of the 
  22.       pioneers in the field of mathematical functions which exhibit 
  23.       chaotic behavior.  In fact Mandelbrot was studying Julia Sets when 
  24.       he discovered the Mandelbrot Set.  This is a more complicated set to 
  25.       understand than the Mandelbrot Set and will be treated later in this 
  26.       documentation.
  27.       
  28.       
  29.       A Short Mathematics Lesson:
  30.       
  31.       This is not mandatory reading, but only for those interested in the 
  32.       details of the calculations the computer is making.  Think of your 
  33.       computer screen as an X Y plane.  To make it a complex plane, we 
  34.       assign a vector Z to any point on the plane with the equation
  35.                      Z = X + iY
  36.       where i in the square root (sqrt) of -1.  Of course, there is no 
  37.       sqrt -1 and by conversion i is called 'imaginary'.  Using ordinary 
  38.       algebra         2        2    2   2
  39.                      Z = (X+iY)  = X - Y +2iXY.
  40.       All the algebra of complex numbers follows the algebra of ordinary 
  41.       numbers where the 'real' terms are collected together and treated as 
  42.       one group and the 'imaginary' terms are collected and treated as 
  43.       another group.  This makes the 'real' and 'imaginary' axes 
  44.       independent or orthogonal.  Note i * i = -1.
  45.        
  46.       The magnitude of Z is defined as the length of the X Y vector
  47.                                           2   2
  48.                      magnitude(Z) = sqrt(X + Y ).
  49.       
  50.       The points in the  Mandelbrot Set are calculated in the following 
  51.       way.  Define the recursive formula
  52.                            2
  53.                    Z    = Z  + C
  54.                     n+1    n
  55.       
  56.                                       - 1 -
  57.       where Z is defined as 0 on the first pass and C is a point in the 
  58.       complex plane.  This formula is calculated over and over again until 
  59.       its magnitude exceeds 2.  This formula has the curious property that 
  60.       as long as the magnitude of the complex vector remains less than 2 
  61.       the magnitude of the next recursion may also be less than 2. 
  62.       However, once the magnitude exceeds 2 it will never again be less 
  63.       than 2 and reach very large magnitudes over the next few 
  64.       recursions.  The fascinating thing about this recursion is that 
  65.       adjacent points which have almost identical coordinates have greatly 
  66.       different magnitude stability, i.e. one point may quickly 'blow up' 
  67.       and the other not.
  68.       
  69.       
  70.       Plotting The Points:
  71.       
  72.       Each point on your computer screen represents a point which has a 
  73.       stability associated with it as defined above.  Each point on your 
  74.       computer screen in the graphics mode has a pixel associated with 
  75.       it.  The MSET12 program calculates the stability of each point on 
  76.       the screen and assigns a pixel color and brightness as a function of 
  77.       the stability of the point.  Some points are infinitely stable, e.g. 
  78.       X = Y = 0.  Others blow up immediately,
  79.       e.g. (X*X+Y*Y) > 4.  Between these extremes there are relatively 
  80.       sharp boundaries, and it is at these boundaries that the beauty of 
  81.       the Mandelbrot Set lies.  The MSET12 program allows the user to set 
  82.       the location of the central pixel on the screen, the range of values 
  83.       of the pixels calculated over the screen's surface, and the palette 
  84.       of pixel colors and brightness assigned to the pixels as a function 
  85.       of the point's stability.
  86.       
  87.       
  88.       RUNNING MSET12:
  89.       
  90.       There are four parameters which are used to control the MSET12 
  91.       program;
  92.       - the type of graphic display,
  93.       - the number of iterations of the recursion executed before the 
  94.            program deems the point 'stable' and moves to the next pixel,
  95.       - and the palette used to determine the pixel values (colors),
  96.       - the location of the center pixel on the screen,
  97.       - the range of pixel values covered by the X and Y axes,
  98.       
  99.       The program is started by typing MSET12 and a carriage return.  You 
  100.       will then be asked which graphics card is installed in your computer 
  101.       by using the function keys. Next, you can choose the number of 
  102.       iterations desired. Then you select the palette desired.  How the 
  103.       points appear on the screen, however, depends on the palette 
  104.       chosen.  There are five palettes available.  Each palette will 
  105.       change the appearance the array calculated.  As a rule, low palette 
  106.       numbers are better for the larger ranges.  For example, palette 1 or 
  107.       2 will produce more attractive displays with ranges larger than 0.1 
  108.       while palettes 3 and 4 will be better for ranges less than 0.1.  
  109.       This is not a hard rule and they all will produce interesting 
  110.       displays provided the location and range define an interesting 
  111.                                       - 2 -
  112.       area.  And then there is the matter of aesthetics.  The user is 
  113.       encouraged to experiment.  Palette 5 is recommended for use with the 
  114.       Hercules monochrome adapter card.  Finally, the program will then 
  115.       prompt you for the X and Y values of the center pixel and the range 
  116.       of the pixel values for the X axis.  For example, if the X value 
  117.       entered is 0 and the range value entered is 1, the range of the X 
  118.       axis will be from -0.5 to +0.5.  The range of the Y axis will be 
  119.       automatically set so that the image is not distorted.  The smaller 
  120.       the range, the greater the magnification.
  121.       
  122.       MSET12 now has all the parameters needed to calculate the stability 
  123.       of a large array of points on the computer screen.  It takes a long 
  124.       time to complete a Mandelbrot Set.  Just how long depends on the 
  125.       display selected, the computer clock rate, the microprocessor (8088 
  126.       or 80286), whether there is a coprocessor present, and the nature of 
  127.       the area selected (stable areas take longer to calculate than 
  128.       unstable areas).  The CGA display requires 64,000points, EGA 
  129.       requires 128,000 points, extended EGA requires 243,200 points, and 
  130.       the Hercules requires 250,560 points.  The coarse Hercules mode 
  131.       plots only 62,000 large pixels and is four times faster than the 
  132.       normal Hercules mode.  If you have an EGA display, chances are that 
  133.       it is CGA compatible so you might wish to search with the CGA mode 
  134.       until you have found an interesting area and then use the EGA mode 
  135.       to display the final product.  Rough approximations are that a 10mHz 
  136.       AT with an 80287 coprocessor in the CGA mode and in an unstable area 
  137.       can complete an image in 5 minutes where a Hercules monochrome 
  138.       graphics equipped 4.7mHz XT in the Hercules mode in a stable area 
  139.       can take over 18 hours.  Patience is required, but the results are 
  140.       often worth it.  Extreme patience is required if you do not have a 
  141.       coprocessor.  If you run out of patience, you can stop the process 
  142.       by typing 'S' for stop and then any key to clear the screen.  When 
  143.       the image is complete, touching any key will clear the screen and 
  144.       return to the command line.
  145.       
  146.       
  147.       Tips
  148.       
  149.       A good way to begin is to view the entire region of interest in the 
  150.       Mandelbrot Set.  Enter the location X = -.5, Y = 0 and a 
  151.       Range = 3.  The dark areas near the center of the screen are very 
  152.       stable areas.  They are sometimes called 'lagoons'.  The borders to 
  153.       the lagoons have the most intricate patterns and are the most 
  154.       interesting to investigate.  The dark areas near the edges of the 
  155.       screen are very unstable and of no interest.  This is a slow image 
  156.       to complete because there are many stable points in the image.  
  157.       Images with many stable points proceed much faster if a low number 
  158.       of iterations are selected.   Next, it is instructional to locate an 
  159.       interesting area and to zoom in on it with successively smaller 
  160.       ranges (larger magnifications).  One of the most fascinating 
  161.       characteristics of the Mandelbrot Set is that no matter how high the 
  162.       magnification of the Set, the detail is never lost.  Note also that 
  163.       the patterns repeat over and over again.  The characteristic of 
  164.       repetitive patterns at finer and finer detail is called 'fractal', a 
  165.       word coined by Benoit Mandelbrot.  The MSET12 uses single precision 
  166.                                       - 3 -
  167.       floating point in its calculations for speed.  This is the only 
  168.       limit to the detail in the patterns and is not a problem to even the 
  169.       serious user.  Try the following series:
  170.       
  171.             X         Y        Range       Palette
  172.       
  173.            -0.8      0.25      .5          1
  174.       
  175.            -0.75     0.15      .1          2
  176.       
  177.            -0.75     0.113     .02         3
  178.       
  179.       Note that the magnification for each of the series has been 
  180.       increased by a factor of 5 over the previous one.
  181.       
  182.       Now that you have the idea, you are on your own.  Continue this 
  183.       series, or try something new.  It is very useful to keep a notebook 
  184.       or log of the points you have tried or are trying.  Believe me, 
  185.       having your computer grinding away for hours on a Set which proves 
  186.       to be beautiful and not remembering the location and range is very 
  187.       frustrating!
  188.       
  189.       
  190.       JULIA SETS:
  191.       
  192.       When you run the JSET12 program you will notice that the menus are 
  193.       almost the same as the MSET12 program.  That is because the equation 
  194.       solved to generate Julia Set is the same as the equation used for 
  195.       the Mandelbrot.  Much of what we have said about the Mandelbrot Set 
  196.       could also be said of the Julia Set.
  197.       
  198.       Another Mathematics Lesson
  199.       
  200.       The mathematics lesson above was not mandatory.  If you wish to 
  201.       master the use of the JSET12 program, however, it is necessary to 
  202.       have a basic understanding of the math involved.  Nothing very deep, 
  203.       mind you, but at least a little understanding.  If you have skipped 
  204.       the mathematics tutorial above, read it now before you proceed.
  205.       
  206.       To generate the Mandelbrot Set, we set Z = 0 on the initial pass 
  207.       through the equation                    0
  208.                             2
  209.                      Z   = Z   + C
  210.                       n+1   n
  211.       and expanded the equation in the complex plane of C.  Notice that 
  212.       this equation has two complex terms; C and Z.  Each of these terms 
  213.       represents a two dimensional plane, and the planes are not in the 
  214.       same space.  In fact, it is not possible for these planes to have 
  215.       more than one point in common.  The Julia Set is generated by 
  216.       setting the value of C as a constant for a whole set and 
  217.       incrementing the real and imaginary parts of Z to define the pixel 
  218.                                                     0
  219.       
  220.                                       - 4 -
  221.       values across the computer screen.  The Mandelbrot Set expands the 
  222.       equation in the C plane and the Julia Set expands the same equation 
  223.       in the Z plane.  The characteristics of the Julia Set are important 
  224.               0
  225.       to understand if you are to control the images produced.  If C 
  226.       values are picked which are in a stable region of the Mandelbrot 
  227.       Set, Then the Julia Set will appear as a connected figure with a 
  228.       boundary which may appear simple.  As the value of C is moved near 
  229.       edge of a stable region in the Mandelbrot Set, the boundary of the 
  230.       Julia Set exhibits a more complicated structure.  Once the value of 
  231.       C crosses the Mandelbrot boundary into an unstable region, the Julia 
  232.       Set explodes into a set of of small regions which quickly evaporate 
  233.       as the value of C moves further into the unstable region.  Because 
  234.       the appearance of the Julia Set depends on the value of C chosen, 
  235.       there are as many Julia Sets as there are values of C.  There are 
  236.       many Julia Sets, there is only one Mandelbrot Set.  
  237.       
  238.       
  239.       RUNNING JSET12:
  240.       
  241.       It is assumed that the reader has already read the MSET12 
  242.       instructions and run the program.  JSET12 is very similar.  The 
  243.       major difference is seen when the values controlling the calculation 
  244.       of the Set are entered.  You are first asked to enter the complex 
  245.       values Z (X and Y). It is possible to position the center of the 
  246.       JSET12 image on the screen by the selection of Z values.  You will 
  247.       then enter the complex values for C.  This parameter must be entered 
  248.       with high precision if it is near the boundary of the Mandelbrot Set 
  249.       because it is very sensitive in this region.  The boundary of the 
  250.       Julia Set shows the same fractal character as the Mandelbrot Set, 
  251.       even under high magnification.  Finally you will enter the range 
  252.       which the value of Z will be varied.  The magnitude of the range 
  253.       controls the magnification of the image.  Small values lead to a 
  254.       high magnification.  
  255.       
  256.       
  257.       Tips
  258.       
  259.       Let us start by viewing the Julia Set associated with the Mandelbrot 
  260.       example in 'Tips' above.  We now must enter four coordinates as well 
  261.       as the range.  When the computer is started on a Julia set using a 
  262.       Hercules display, it may take several minutes for the image to begin 
  263.       to show.  Notice how many of the shapes resemble each other in the 
  264.       true fractal fashion.  They may remind you of elephants.  The second 
  265.       example is very near the edge of the Mandelbrot Set and has begun to 
  266.       evaporate and break up into a set of separate pinwheels.  Try some 
  267.       other changes and see what happens.
  268.                                       - 5 -
  269.       
  270.             X       Y      real C      imag C      Range       Palette
  271.       
  272.             0       0      -.74543     .11301      3           5
  273.       
  274.             0       0      -.76        .11301      3           5
  275.       
  276.       
  277.       The palettes used when displaying JSET12 can alter the appearance of 
  278.       the set just as it is in MSET12.  The need to change palettes as you 
  279.       go to high magnification is not as critical because you will usually 
  280.       work with low magnification so that you can display a full set to 
  281.       enjoy its symmetry.  Palette 5 is always a good choice whether 
  282.       displaying Hercules, CGA, or EGA.  The other palettes, however, 
  283.       should not be ignored because they sometimes make pleasing designs.
  284.       
  285.       Let's try another series:
  286.       
  287.             X       Y      real C      imag C      Range       Palette
  288.       
  289.             0       0      .25          0          3          choose any
  290.       
  291.             0       0      .255         0          3          but keep it
  292.       
  293.             0       0      .26          0          3          the same for
  294.       
  295.             0       0      .26          .001       3          the whole
  296.       
  297.             0       0      .26          .002       3          series
  298.       
  299.       Notice how sensitive the image is to these small changes in the 
  300.       parameters.  Now let's zoom in on the last set with 6 times 
  301.       magnification.  The center of the screen is repositioned with 
  302.       changes in the X and Y values.
  303.       
  304.             X       Y      real C      imag C      Range       Palette
  305.       
  306.             .25     .88    .26          .002       .5          any
  307.       
  308.       The beauty of the set's symmetry is lost, but notice how the fine 
  309.       detail remains in true fractal fashion.  Julia Sets offer more 
  310.       variety than Mandelbrot Sets and include aesthetically pleasing 
  311.       symmetry.  If you would like to see the area of the Mandelbrot Set 
  312.       you are in, run MSET12  and enter:
  313.       
  314.             X         Y        Range       Palette
  315.       
  316.            .27        0         .05         3
  317.       
  318.       The area is that in the center left of the screen.  Now you are on 
  319.       your own to do some exploring.
  320.       
  321.       
  322.       
  323.                                       - 6 -
  324.       
  325.       
  326.       CONCLUSION:
  327.       
  328.       
  329.       MSET12 and JSET12 are (c) copyrighted by Image Laboratories.  They 
  330.       are for private use only and may not be modified or sold 
  331.       commercially without written permission.  These programs may be 
  332.       copied freely for private use.
  333.       
  334.       If you like the MSET12 and JSET12 programs, support them by sending 
  335.       $35 to:
  336.       
  337.       
  338.            Image Laboratories
  339.            67 Old Stage Road
  340.            Chelmsford, MA  01824
  341.       
  342.       
  343.       In return, you will receive the latest version of the MSET and JSET 
  344.       programs which will allow you to save and display the Mandelbrot and 
  345.       Julia Sets you have generated and to color these images with your 
  346.       own palettes instead of the ones provided with the program.  This 
  347.       allows you to save your best images for easy, fast display at a 
  348.       future time and for you to apply your own artistic interpretation to 
  349.       them.
  350.       
  351.